package Spackage;

public class Student
{
        private String name;
        private String birthdate;
        private String sex;

        private static String subject = "计算机科学与技术";

        public Student(String name, String birthdate, String sex)
        {
            this.name = name;
            this.birthdate = birthdate;
            this.sex = sex;
        }

        public int getAge()
        {
            return 21;
        }

        public static void printStudentInfo(Student student)
        {
            System.out.println("subject:"+subject+",name:"+student.name+",Sex:"+student.sex+",birth:"+student.birthdate+",age:"+student.getAge());
        }

        public static void main(String[] args)
        {
            Student student1 = new Student("张三","2000/1/10","男");
            Student student2 = new Student("李四","2000/7/10","男");
            Student student3 = new Student("王五","2000/12/10","男");

            printStudentInfo(student1);
            printStudentInfo(student2);
            printStudentInfo(student3);
        }

}
